Raw image data captured from an image capture device such as a video or still picture camera often is conventionally captured using a Bayer filter mosaic which is a color filter array (CFA) arranging red, green, and blue color filters on a square grid of photosensors. The Bayer filter is used in many digital image sensors to create a color image. The filter pattern for one example Bayer filter is 50% green, 25% red and 25% blue. In other words, for every 2×2 group of pixels, two diagonally opposed pixels provide a green intensity or hue value, while one of the other pixels provides a red value, and the fourth pixel provides a blue value.
In order to form or display images from image data obtained using a Bayer filter, demosaicing algorithms are used to determine the missing color components, whether red, green, or blue component values, so that each pixel has red, green, and blue (RGB) values to combine the components together to form a specific color at the pixel. This is typically performed by using some form of bilinear interpolation using color values at surrounding pixels and of the same color to determine the color value for a current pixel. The conventional demosaicing algorithms, however, may result in color artifacts due to mis-registration of the colors, and therefore the inability to provide a high quality image.